<?php
class ActiveClients extends HTech_Db_Table
{
    protected $_name    = 'view_active_clients';
    protected $_primary = 'ClientId';  
    
    protected function _setGridMetadata()
    {
        $this->_gridMetadata['title'] = $this->translate("Active clients");
        $this->_gridMetadata['params'] = array('OfficerUserId','CommunityId','LocationId');
        $this->_gridMetadata['onClick'] = 'admin.client.view';
        $this->_gridMetadata['headers'] = array
            (
                array('ClientId',          50, $this->translate("Id"), 'Number'),
                array('OfficerUsername',   85, $this->translate("Officer"), 'String'),
                array('LocationShortName', 70, $this->translate("Branch"), 'String'),
                array('Community',        150, $this->translate("Community"), 'String'),
                array('CommunityType',     80, $this->translate("Com. type"), 'String'),
                array('GroupName',        250, $this->translate("Group"), 'String'),
                array('Code',             100, $this->translate("Identity number"), 'String'),
                array('CodeType',         100, $this->translate("Id. type"), 'String'),
                array('Gender',            60, $this->translate("Gender"), 'String'),
                array('Birthdate',         80, $this->translate("Birthdate"),     'DateTime', 'Date'),
                array('FullName',         180, $this->translate("Name"), 'String'),
                array('NickName',          80, $this->translate("Nickname"), 'String'),
                array('Children',          80, $this->translate("Children"), 'String'),
                array('Dependents',        80, $this->translate("Dpndnts"), 'String'),
                array('HomePhone',        100, $this->translate("Home phone"), 'String'),
                array('MobilePhone',      100, $this->translate("Mobile phone"), 'String'),
                array('Comments',         200, $this->translate("Comments"), 'String')
            );
        return $this;
    }
}